package com.pktechan.manage.enumeration;

public enum OperateLogTypeEnum {
    CREATE(1, "创建"), EDIT(2, "修改"), DELETE(3, "删除"), QUERY(4, "查询"), EXPORT(5, "导出"), IMPORT(6, "导入"), OTHER(7, "其他"), CONFIRM(8, "确认"),
    REPORT_THE_LOSS(9,"挂失") ,RELIEVE_REPORT_THE_LOSS(10,"解除挂失"),CANCEL_ACCOUNT(11,"撤销账户"),
    FROZEN(12,"冻结"),UN_FROZEN(13,"解除冻结"),LIQUIDATION_TOHONOUR(14,"清盘及兑付"), REJECT(15, "驳回");

    private Integer code;
    private String name;


    OperateLogTypeEnum(Integer code, String name) {
        this.code = code;
        this.name = name;
    }

    public static OperateLogTypeEnum getByCode(Integer code) {
        for (OperateLogTypeEnum operateType : OperateLogTypeEnum.values()) {
            if (operateType.getCode().equals(code)) {
                return operateType;
            }
        }
        return null;
    }

    public Integer getCode() {
        return code;
    }

    public String getName() {
        return name;
    }
}
